//
//  PrefixExpression.swift
//  PrattParser
//
//  Created by 神经骚栋 on 2023/9/13.
//

import Cocoa

class PrefixExpression: Expression {
    
    public var operatorValue: String?

    public var right: Expression?

    init(operatorValue: String? = nil, right: Expression? = nil) {
        super.init()
        self.operatorValue = operatorValue
        self.right = right
    }
    
    public func toString() -> String? {
        let string : String? = "(" + (operatorValue ?? "") + ")" + "\n";
        return string
    }    
}
